<%- include header %>
    <section class="container u_main_box">
        <div class="u_main_inner">
            <div class="u_main">
                <ul class="u_main_ul">
                    <% if (posts.length) {%>
                    <li>
                        搜索结果如下：
                    </li>
                    <% } %>
                    <% posts.forEach(function (post, index) { %>
                        <li @click.stop="goTo" data-url="<%= post._id %>">
                            <div class="u_ar_info">

                                <!-- 文章标签 -->
                                <%- include label %>
                                <a href="/u/<%= post.name %>">
                                    <%= post.name %>
                                </a>
                                <span>
                                    <%= post.time.minute %>
                                </span>
                                <% if (user && user.name==post.name) { %>
                                    <a href="/edit/<%= post._id %>" class="u_edit">·编辑</a>
                                    <% } %>
                            </div>
                            <div class="u_ar_title">
                                <a href="/detail/<%= post._id %>">
                                    <%= post.title %>
                                </a>
                            </div>
                        </li>
                    <% }) %>
                </ul>
                <% if (!posts.length) {%>
                    <div class="u_nodata">
                        sorry，没有找到你想要的文章
                    </div>
                <% } %>
            </div>
            <%- include paging %>
        </div>
    </section>
    <%- include footer %>